<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

class CreateBookCommentsStartTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('book_comments_start', function (Blueprint $table) {
            $table->bigIncrements('id');
            $table->integer('user_id')->comment('用户');
            $table->integer('comments_id')->comment('评论id');
            $table->tinyInteger('type')->comment('是否赞同；1赞同；2不赞同');
            $table->tinyInteger('status')->default(1)->comment('状态:1成功;2取消');
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('book_comments_start');
    }
}
